﻿CREATE TABLE [dbo].[content_item] (
    [content_item_id]    BIGINT         IDENTITY (1, 1) NOT NULL,
    [title]              NVARCHAR (255) NULL,
    [abstract]           NVARCHAR (255) NULL,
    [body]               TEXT           NULL,
    [created]            DATETIME       NULL,
    [info_source_name]   NVARCHAR (255) NULL,
    [info_source_url]    NVARCHAR (255) NULL,
    [publish_state_date] DATETIME       NULL,
    [publish_comment]    NVARCHAR (255) NULL,
    [created_by_id]      BIGINT         NULL,
    [publish_state_id]   BIGINT         NULL,
    [publish_state_by]   BIGINT         NULL,
    CONSTRAINT [PK__content___4B97A4684222D4EF] PRIMARY KEY CLUSTERED ([content_item_id] ASC),
    CONSTRAINT [FK_content_item_users] FOREIGN KEY ([created_by_id]) REFERENCES [dbo].[users] ([user_id]),
    CONSTRAINT [FK_content_item_users1] FOREIGN KEY ([publish_state_by]) REFERENCES [dbo].[users] ([user_id])
);





